![IBASE Technology MBD301 Скачать руководство пользователя страница 63](http://html1.mh-extra.com/html/ibase-technology/mbd301/mbd301_user-manual_605016063.webp)
Appendix
MBD301
User’s Manual
55
printf("Fintek 81846 watch dog program\n");
SIO = Init_F81846();
if (SIO == 0)
{
printf("Can not detect Fintek 81846, program abort.\n");
return(1);
}//if (SIO == 0)
if (argc != 2)
{
printf(" Parameter incorrect!!\n");
return (1);
}
bTime = strtol (argv[1], endptr, 10);
printf("System will reset after %d seconds\n", bTime);
if (bTime)
{
EnableWDT(bTime); }
else
{
DisableWDT(); }
return 0;
}
//---------------------------------------------------------------------------
void EnableWDT(int interval)
{
unsigned char bBuf;
bBuf = Get_F81846_Reg(0x2B);
bBuf &= (~0x20);
Set_F81846_Reg(0x2B, bBuf);
//Enable WDTO
Set_F81846_LD(0x07);
//switch to logic device 7
Set_F81846_Reg(0x30, 0x01);
//enable timer
bBuf = Get_F81846_Reg(0xF5);
bBuf &= (~0x0F);
bBuf |= 0x52;
Set_F81846_Reg(0xF5, bBuf);
//count mode is second
Set_F81846_Reg(0xF6, interval);
//set timer
bBuf = Get_F81846_Reg(0xFA);
bBuf |= 0x01;
Set_F81846_Reg(0xFA, bBuf);
//enable WDTO output
bBuf = Get_F81846_Reg(0xF5);
bBuf |= 0x20;
Set_F81846_Reg(0xF5, bBuf);
//start counting
}
//---------------------------------------------------------------------------
void DisableWDT(void)
{
unsigned char bBuf;
Set_F81846_LD(0x07);
//switch to logic device 7
Содержание MBD301
Страница 1: ...MBD301 AMD Ryzen Desktop Processor Mini ITX Motherboard User s Manual Version 1 0 November 2019 ...
Страница 8: ...viii MBD301 User s Manual This page is intentionally left blank ...
Страница 13: ...General Information MBD301 User s Manual 5 1 1 6 Block Diagram ...
Страница 16: ...8 MBD301 User s Manual This page is intentionally left blank ...
Страница 21: ...Hardware Configuration MBD301 User s Manual 13 2 2 3 Jumper Connector Locations MBD301 Figures of MBD301 ...
Страница 42: ...34 MBD301 User s Manual ...
Страница 49: ...BIOS Setup MBD301 User s Manual 41 4 4 4 6 CPU Configuration 4 4 7 USB Configuration ...