OpenMediaVault (PINE A64(+)) 4.13.10 [Nov 21] | OpenMediaVault (A64-LTS / SOPINE) 4.13.10 [Nov 21] | Q4OS (PINE A64(+)) 2.4-r1 [Nov 10] | Volumio (ROCK64) 2.299 [Oct 30] | Q4OS (Pinebook) 2.4-r1 [Oct 30] | DietPi (ROCK64) v156 [Oct 24] | Armbian - Xenial Desktop (Pinebook) 5.34 [Oct 24] | motionEyeOS (PINE A64(+)) 20171003 [Oct 23] | Android Images (ROCK64) 20171012 [Oct 23]

Getting Started | Visit the WIKI | IRC Logs | Forum Rules/Policy


Wifi problem at 166Mhz
#1
Hi all 
If i use RtlDuino (arduino for padi stamp) everythings works well , even SD card via SDIO

But if i try to set cpu to 166Mhz caling Init_CPU_CLK_UART with parameter 0 , which caling HalCpuClkConfig(0)

after i call WIFI.begin or WIFI.apbegin system freeze in serial log i can see Hard Fault Error (after Initializing WIFI ...  SPI)
if i set param 1 (83Mhz) everythings its work well

U can test it with example SoftAP (from ameba)

u must add this 
Code:
extern "C" {
void UserPreInit(void)
{
   Init_CPU_CLK_UART(0,38400); 
   // 0 - 166666666 Hz, 1 - 83333333 Hz, 2 - 41666666 Hz, 3 - 20833333 Hz, 4 - 10416666 Hz, 5 - 4000000 Hz
   // 6 - 200000000 Hz, 7 - 10000000 Hz, 8 - 50000000 Hz, 9 - 25000000 Hz, 10 - 12500000 Hz, 11 - 4000000 Hz
}  



at the begin in your sketch (as in another examples)
if u put 1 instead zero everything works

so where is the problem
Reply
#2
Are you having this issue with the RtlDuino SDK or the Ameba sdk? I am slightly confused by the extern "C" block. I do have the Ameba SDK working though so I could possibly try calling the Init_CPU_CLK_UART and see what happens. You seem to have a better idea what you are doing than me, but if you think I can help let me know.
Reply
#3
(11-13-2017, 10:00 AM)Dan Wrote: Are you having this issue with the RtlDuino SDK or the Ameba sdk? I am slightly confused by the extern "C" block. I do have the Ameba SDK working though so I could possibly try calling the Init_CPU_CLK_UART and see what happens. You seem to have a better idea what you are doing than me, but if you think I can help let me know.

I think it is issue RtlDuino SDK, extern C is because symbol Init_CPU_CLK_UART is C lang type and C++ linker dont know it by default this is used if u want mixed c++ and c libraries

so i can use ameba SDK but it does not support SD card on RTL8710, RtlDuino support SDio and its works
Reply
#4
mirecta, first posts are moderated - please post just once. We are getting to the posts as fast as we can. Please read forum rules and policy.
  If you manage to click this link you'll join in the IRC channel
Reply
#5
(11-13-2017, 03:33 PM)Luke Wrote: mirecta, first posts are moderated - please post just once. We are getting to the posts as fast as we can. Please read forum rules and policy.

i understand i am sorry
Reply
#6
Ok, I dont have any experience with the RtlDuino SDK, but based on your problem description I wonder if it is an issue with the RtlDuino SDK supporting clock rates that are different from the stock 83Mhz. I am not sure if anyone has experimented with overclocking and using the RtlDuino SDK.
Reply


Possibly Related Threads...
Thread Author Replies Views Last Post
  Using WiFi API Dan 3 133 10-20-2017, 08:37 AM
Last Post: Dan

Forum Jump:


Users browsing this thread: 1 Guest(s)