RyuX Posted June 20, 2014 Report Share Posted June 20, 2014 Hey guys i ordered a Newhaven OLED 2x20 Display, it seems it doesnt work on my sammichFM.. it just stays black. What am i missing ? Thanks Patrick Quote Link to comment Share on other sites More sharing options...
ilmenator Posted June 20, 2014 Report Share Posted June 20, 2014 Check the datasheet and compare with the "regular" displays! Quote Link to comment Share on other sites More sharing options...
Altitude Posted June 20, 2014 Report Share Posted June 20, 2014 Does the sammich run in 4 or 8 bit mode? Newhaven OLEDs dont like the 4bit midibox implementation Quote Link to comment Share on other sites More sharing options...
RyuX Posted June 20, 2014 Author Report Share Posted June 20, 2014 According to the Datasheet the Pins etc. should be the same. I dont know for the 4/8 bit thing, it isnt displaying anything. Hope someone got a clue.. Quote Link to comment Share on other sites More sharing options...
TK. Posted June 23, 2014 Report Share Posted June 23, 2014 It's very likely a 4/8 bit thing. The solution would be a modified firmware (I could provide the modification if you are interested) and four wires to J16:D3..D0. Could you please already do this hardware modification? Connect: - PIC Pin RE2 to J16:D3 - PIC Pin RE1 to J16:D2 - PIC Pin RB1 to J16:D1 - PIC Pin RB0 to J16:D0 /edit: pinning corrected, this one is working (confirmed by RyuX) Compare following schematic for sammichFM J16 pinning: http://www.midibox.org/dokuwiki/lib/exe/fetch.php?media=sammichfm:sammichfm_base_pcb_rev_1.pdf And following schematic for PIC pinning: http://www.ucapps.de/mbhp/mbhp_core_v3.pdf Best Regards, Thorsten. Quote Link to comment Share on other sites More sharing options...
RyuX Posted June 23, 2014 Author Report Share Posted June 23, 2014 Hey Thorsten ! Thanks for your reply. So i just put 4 wires directly from the PIC to the Digital Pins on J16 to the LCD ? Do i need to cut any traces or just make the new connections in addition ? If i make a firmware update will i have to remodify the firmware? If so could you point me at the part that i need to modify ? Thanks again!!! Quote Link to comment Share on other sites More sharing options...
TK. Posted June 23, 2014 Report Share Posted June 23, 2014 Fortunately there are no tracks routed to J16:D3..D0, therefore you can add the wires without special measures. I'm planning to update the firmware, so that a special flag can be set to enable the 8bit LCD interface option. I would provide you a special precompiled version for testing - but if you already able to compile by yourself, then this would help me (a bit less effort at my side, especially whenever I provide a new firmware) Note that I won't be able to test the enhancement at my side - I hope that it will work immediately at your side, otherwise I will need some time to buy & try the same OLED. Best Regards, Thorsten. Quote Link to comment Share on other sites More sharing options...
RyuX Posted June 23, 2014 Author Report Share Posted June 23, 2014 I dont know yet how to compile the firmware, havent used any programming languages for ages. Ok will do the wiring tomorrow morning, thanks for your effort, would be really nice to get it working. Thanks and best regards Patrick Quote Link to comment Share on other sites More sharing options...
TK. Posted June 23, 2014 Report Share Posted June 23, 2014 Ok, crossing fingers! Please try this version: http://www.ucapps.de/mios/midibox_fm_v1_4j__sammichfm_8bitlcd.zip I've enabled the new USE_8BIT_LCD_DRIVER option for the setup_pic18f4685_sammich_fm.hex file only! Best Regards, Thorsten. Quote Link to comment Share on other sites More sharing options...
RyuX Posted June 23, 2014 Author Report Share Posted June 23, 2014 Thanks Thorsten... will try this version tomorrow after connecting the wires. So basically flashing this firmware should enable the OLED Driver, if i want to use a normal LCD i would flash the standard version again? Will keep you updated on the progress. This could save my day. Greets Patrick Quote Link to comment Share on other sites More sharing options...
TK. Posted June 24, 2014 Report Share Posted June 24, 2014 The USE_8BIT_LCD_DRIVER option will work with all LCDs together with the hardware modification, no need to switch to another firmware version. Best Regards, Thorsten. Quote Link to comment Share on other sites More sharing options...
RyuX Posted June 24, 2014 Author Report Share Posted June 24, 2014 (edited) Hello I did the Mod and flashed the firmware. The normal LCD is not outputting the correct data anymore. The OLED is at least showing the first R of what i guess should be (RANDOM PATCH) and some chars at the end. Maybe you got a hint ? Thanks again EDIT: this is the OLED i got http://de.mouser.com/ProductDetail/Newhaven-Display/NHD-0220DZW-AG5/?qs=sGAEpiMZZMshRHSPqbouvFu0giaJJ%252b33TsxIS1Y%252b3Po%3d Edited June 24, 2014 by RyuX Quote Link to comment Share on other sites More sharing options...
TK. Posted June 24, 2014 Report Share Posted June 24, 2014 The driver is selected and running. But it looks like two wires are swapped. Could you please take an hi-resolution picture of your HW mod, so that I can check if the cables are connected to the right pins? Best Regards, Thorsten. Quote Link to comment Share on other sites More sharing options...
RyuX Posted June 24, 2014 Author Report Share Posted June 24, 2014 (edited) I connected them exactly like you wrote before.. also measure continuity again at those points, here is the pic.. Maybe i overlooked something. Thanks EDIT: Its working now.. i just randomly tried to Switch the Wire RE1 <-> RE2. Did i read the Shematics wrong ? you wrote: - PIC Pin RE1 to J16:D3 - PIC Pin RE2 to J16:D2 - PIC Pin RB1 to J16:D1 - PIC Pin RB0 to J16:D0 /moderator edit: this is the wrong pinning, documentation has been corrected in TK's posting above Well nevermind.. its working so i am supper happy !! :D Edited June 24, 2014 by TK. Quote Link to comment Share on other sites More sharing options...
TK. Posted June 24, 2014 Report Share Posted June 24, 2014 Cool! :smile: Yes, the pin specification was wrong, I corrected it in my posting above. Best Regards, Thorsten. Quote Link to comment Share on other sites More sharing options...
RyuX Posted June 24, 2014 Author Report Share Posted June 24, 2014 Thanks again Thorsten.. had to put some more work into it.. because the OLED is not nearly as high as the LCD.. so i had to remount it on the top and solder longer pins to it. Now finally it looks like the Shruthi XT and fits inside my Studio :sweat: Thanks for making it possible :w00t: Best Regards Patrick Quote Link to comment Share on other sites More sharing options...
Hawkeye Posted June 25, 2014 Report Share Posted June 25, 2014 (edited) Looks awesome! Congrats and enjoy your OLEDs! :-) (The gameboy might be a little bit more difficult to convert ;-)) Many greets! Peter Edited June 25, 2014 by Hawkeye Quote Link to comment Share on other sites More sharing options...
Academic Planner Posted January 23, 2019 Report Share Posted January 23, 2019 On 6/23/2014 at 5:18 PM, TK. said: Ok, crossing fingers! Please try this version: http://www.ucapps.de/mios/midibox_fm_v1_4j__sammichFM_8bitlcd.zip I've enabled the new USE_8BIT_LCD_DRIVER option for the setup_pic18f4685_sammich_fm.hex file only! Best Regards, Thorsten. Is there any chance someone could fix this link? I just purchased a Vishay OLED for my Sammich, but it seems the wiring modification isn't working. Perhaps my firmware needs updating? Quote Link to comment Share on other sites More sharing options...
Academic Planner Posted January 29, 2019 Report Share Posted January 29, 2019 No one? Quote Link to comment Share on other sites More sharing options...
Antichambre Posted January 29, 2019 Report Share Posted January 29, 2019 1 hour ago, Academic Planner said: No one? Hi! how are you? Could you share Oled reference or datasheet? Best Bruno Quote Link to comment Share on other sites More sharing options...
Academic Planner Posted January 30, 2019 Report Share Posted January 30, 2019 19 hours ago, Antichambre said: Hi! how are you? Could you share Oled reference or datasheet? Best Bruno Hey, long time no speak! Thanks for the reply. Here's the data sheet:https://www.mouser.com/datasheet/2/427/oled020n002awpp5n00000-1510781.pdf Quote Link to comment Share on other sites More sharing options...
Antichambre Posted January 30, 2019 Report Share Posted January 30, 2019 (edited) The pinout is good. First did you check with standard 4 bit, without USE_8BIT_LCD_DRIVER option? The controller is OLED-0010(WS0010) and seems to match HD44780 industrial standard BUT in the command table there's something which differs: Page 22 of the controller datasheet Maybe I'm wrong but this specific command is nowhere in the LCD initialisation: USER_LCD_Init ;; notify that no graphical LCD is connected bcf MIOS_BOX_CFG0, MIOS_BOX_CFG0_USE_GLCD ; (Initialization of Ports: done in Init_Ports) SET_BSR USER_LCD_STATUS clrf USER_LCD_STATUS, BANKED movlw 100 ; 100 ms delay call MIOS_Delay bcf USER_LCD_LAT_RW, USER_LCD_PIN_RW ; LCD_WRITE bcf USER_LCD_LAT_RS, USER_LCD_PIN_RS ; USER_LCD_PIN_RS_0 ;; initialize LCD movlw 0x38 movwf USER_LCD_LAT_D rcall USER_LCD_Strobe_Set rcall USER_LCD_Strobe_Clr movlw 50 ; 50 ms delay call MIOS_Delay rcall USER_LCD_Strobe_Set rcall USER_LCD_Strobe_Clr movlw 50 ; 50 ms delay call MIOS_Delay rcall USER_LCD_Strobe_Set rcall USER_LCD_Strobe_Clr movlw 0x08 ; Display Off rcall USER_LCD_Cmd movlw 0x0c ; Display On rcall USER_LCD_Cmd movlw 0x06 ; Entry Mode rcall USER_LCD_Cmd movlw 0x01 ; Clear Display call USER_LCD_Cmd bcf MIOS_LCD_TIMEOUT1, 7, BANKED ; everything ok, make sure that LCD_TIMEOUT, bit 7 is cleared movlw 0x38 ; without these lines the LCD will not work rcall USER_LCD_Cmd ; correctly after a second USER_LCD_Init movlw 0x0c rcall USER_LCD_Cmd movlw 0x00 ; set cursor to zero pos rgoto USER_LCD_CursorSet I think you have to add this command somewhere for "internal DCDC power On" movlw 0x17 rcall USER_LCD_Cmd But I don't remember where, in the app_lcd.inc maybe??? Someone knows???Edit: I don't remember which lcd_init is active, /src/app_lcd.inc /module/app_lcd/clcd/app_lcd.inc /mios/mios_lcd.inc Best Bruno Edited January 30, 2019 by Antichambre Quote Link to comment Share on other sites More sharing options...
Academic Planner Posted January 31, 2019 Report Share Posted January 31, 2019 Yeah, checked the flag beforehand with no success. I suppose I could try adding that bit of code to the related files to see which one sticks? Quote Link to comment Share on other sites More sharing options...
Antichambre Posted January 31, 2019 Report Share Posted January 31, 2019 I think I understood what TK did in the FM firmware. You have to let the 8 bit connections and the USE_8BIT_LCD_DRIVER flag to, this will force the use of the custom driver "app_lcd_8bitdriver.inc" which is in /src/ folder, It's an 8 bit one but it doesn't matter your controller supports it. Replace that file by the one from my dropbox https://www.dropbox.com/s/zpdxe6cfrxtmv04/app_lcd_8bitdriver.inc?dl=1 (I added the command in this file.) movlw 0x08 ; Display Off rcall USER_LCD_Cmd movlw 0x0c ; Display On rcall USER_LCD_Cmd movlw 0x06 ; Entry Mode rcall USER_LCD_Cmd movlw 0x17 ; DCDC Power On (OLED-0010 controller only) rcall USER_LCD_Cmd movlw 0x01 ; Clear Display call USER_LCD_Cmd bcf MIOS_LCD_TIMEOUT1, 7, BANKED ; everything ok, make sure that LCD_TIMEOUT, bit 7 is cleared movlw 0x38 ; without these lines the LCD will not work rcall USER_LCD_Cmd ; correctly after a second USER_LCD_Init movlw 0x0c rcall USER_LCD_Cmd movlw 0x17 ; rcall USER_LCD_Cmd movlw 0x00 ; set cursor to zero pos rgoto USER_LCD_CursorSet Compil it, upload and tell me... Quote Link to comment Share on other sites More sharing options...
Academic Planner Posted February 6, 2019 Report Share Posted February 6, 2019 It seems I'm having trouble compiling. I followed the directions at the following link, but something still isn't working on my end. I think it might be an issue with Windows. http://www.midibox.org/dokuwiki/windows_toolchain_quickstart Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.