Think I Might Have Bricked My Unihiker

userHead Marc.Helfman 2024-02-23 23:46:38 1192 Views5 Replies

Every so often, when you first start running a Python program in Mind+, the IDE takes several seconds to erase some memory locations on the Unihiker. On one such occasion, I accidentally hit the Stop button. Now I get an error message if I try to run a program that has code to read an analog value from a sensor connected to one of the 3 pin I/O ports on the side of the Unihiker.

2024-09-23 03:34:34

I was getting this happen at times myself. But this may explain it :)

 

" It means that PinPong firmware initialization failed.
Case 1: It may be that multiple programs are running at the same time. For example, a program is started in the home menu of the board, and another program is run in Mind+. Both programs use the pinpong library.
Solution: first try to press and hold the Home button for 5 seconds and release it, which will close all currently running python programs, and restart the board if an error is still reported.
Case 2: You can try to re-initialize the mcu firmware,run this code:
from pinpong.board import Board
Board().begin(1)"

from bottom of page at:
https://www.unihiker.com/wiki/Troubleshooting/Error_RuntimeError_Analog_map_retrieval_time_out_or_the_readings_from_onboard_components_all_0/

 

userHeadPic Tony.Walsh
2024-04-07 20:17:37

I tried the re-install of the OS on https://www.unihiker.com/wiki/burner, but after I downloaded the image file and tried to load it as in step 3, I got a message saying the the image was damaged. 

 

userHeadPic Marc.Helfman
2024-03-20 19:08:05

This error usually means that there is a program running on the Unihiker that includes pinpong. You can try refreshing the firmware of the GD32 coprocessor, as per these instructions:

https://www.unihiker.com/wiki/faq#Error:%20RuntimeError:%20Analog%20map%20retrieval%20time%20out.%20or%20the%20readings%20from%20onboard%20components%20all%200

userHeadPic LL
2024-02-24 01:01:45

Would you post your code and your error message?

Or try to re-install the OS?

 

Tutorial:

https://www.unihiker.com/wiki/burner

userHeadPic Yeez_B
Marc.Helfman wrote:

Thanks for the quick reply. Here's the code snippet:

 

from pinpong.board import *

import time

 

Board('unihiker').begin()

 

adc = ADC(Pin(Pin.P21))

 

while True:

    value = adc.read()

    print(value)

    time.sleep(0.1)

 

and here's the error message:

RuntimeError: *** Analog map retrieval timed out *** Do you have Arduino connectivity and do you have the correct Firmata sketch uploaded to the board?

 

Thanks for OS re-install link; I'll give it a try.

 

2024-02-24 21:36:26
1 Replies