File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -1837,10 +1837,10 @@ void initDisplay(){
18371837 bbepSendCMDSequence (&bbep, bbep.pInitFull );
18381838 String chipId = getChipIdHex ();
18391839 String infoText = " opendisplay.org\n Name: OD" + chipId + " \n FW: " + String (getFirmwareMajor ()) + " ." + String (getFirmwareMinor ()) + " \n Firmware by\n Jonas Niesner" ;
1840- if (globalConfig.displays [0 ].transmission_modes & TRANSMISSION_MODE_CLEAR_ON_BOOT) writeTextAndFill (" " );
1841- else writeTextAndFill (infoText.c_str ());
1840+ if (! (globalConfig.displays [0 ].transmission_modes & TRANSMISSION_MODE_CLEAR_ON_BOOT)){
18421841 bbepRefresh (&bbep, REFRESH_FULL);
18431842 waitforrefresh (60 );
1843+ }
18441844 pwrmgm (false );
18451845 }
18461846 else {
@@ -1973,9 +1973,15 @@ void sendResponse(uint8_t* response, uint8_t len){
19731973 writeSerial (" ERROR: Response too large for queue (" + String (len) + " > " + String (MAX_RESPONSE_SIZE) + " )" );
19741974 }
19751975 #endif
1976- #ifndef TARGET_ESP32
1977- delay (20 );
1978- writeSerial (" Response sent successfully" );
1976+ #ifdef TARGET_NRF
1977+ // NRF devices send BLE notifications directly
1978+ if (Bluefruit.connected () && imageCharacteristic.notifyEnabled ()) {
1979+ imageCharacteristic.notify (response, len);
1980+ writeSerial (" NRF: BLE notification sent (" + String (len) + " bytes)" );
1981+ } else {
1982+ writeSerial (" ERROR: Cannot send BLE response - not connected or notifications not enabled" );
1983+ }
1984+ delay (20 ); // Brief delay to let BLE stack process
19791985 #endif
19801986}
19811987
You can’t perform that action at this time.
0 commit comments