You are reading a single comment by @jeffmer and its replies. Click here to read the full conversation.
  • @yngv126399 I got hold of an SN80 recently to play with circular displays and I have now fixed the lcd_spi_unbuf driver. The problem was that for some reason, no pixels are displayed if the address window you set up is not completely filled. This means that double buffering does not work, so I have fixed the problem for single buffering - just remove the -DLCD_SPI_DOUBLEBUF=1 declaration in the board file. I have left a firmware build with the revised driver here . I have got most of the P8 bangle emulation environment to run on the SN80 including accelerometer, touch screen and heart rate sensor- see picture below.

    .

    I have made the widgets moveable, so you can specify the location of the widget panel. The clock face above moves the panel top or bottom to minimse it being obscure by the hour hand.

    The only remaining problem is the physical button which should be on D13 or D17, however, I have tried these and other unallocated pins with no success. I would be interested to know if you have got the button to work as I suspect that I may have a hardware fault. I am currently using long touch to replace the button - which works OK.

  • That's great! I actually am running with my own driver for the moment... not as good, but for setPixel, I just set the color and go.. I don't buffer even the one line; so it's slower but I got it to work. I tried taking out double buffering but it didn't work for me... but I'll try your version for sure.

    As for the button, I did get it to work.. According to atc1441's notes, btn1 is D9, and that works as long as you pull D17 high. I'm sure there's a less hacky way, but I defined two buttons, the second one being D17, and pull it high:

     'BTN1' : { 'pin' : 'D9'} ,
     'BTN2' : { 'pin' : 'D17', 'pinstate' : 'IN_PULLUP'} ,
    
About

Avatar for jeffmer @jeffmer started