วันพฤหัสบดีที่ 29 พฤศจิกายน พ.ศ. 2561

Arduino Dot Matrix DS3231 แก้ปัญหาเวลาไม่โชว์ printStringWithShift

Module  DS3231 ส่งค่าไปที่ dotMatrix แล้วไม่ออก หรือเป็นตัวอักษรที่อ่านไม่ได้ ไปเจอวิธีนี้มา เก็บไว้ก่อนเดี๋ยวลืม

    DateTime now = RTC.now(); 

    int dtxt = now.day();
    char dstr[0];
    itoa(dtxt, dstr,10);
    printStringWithShift("    ",15);     
    printStringWithShift(dstr,15); 
 
    int mtxt = now.month();
    char mstr[0];
    itoa(mtxt, mstr,10);
    printStringWithShift("/",15);
    printStringWithShift(mstr,15);
 
    int ytxt = now.year();
    char ystr[0];
    itoa(ytxt, ystr,10);
    printStringWithShift("/",15);
    printStringWithShift(ystr,15); 

    float tmtxt = RTC.getTemperature();
    char tmstr[0];
    itoa(tmtxt, tmstr,10);
    printStringWithShift("  Temperature : ",15);
    printStringWithShift(tmstr,15); 
     
    printStringWithShift("'C        ",15);

วันจันทร์ที่ 26 พฤศจิกายน พ.ศ. 2561

เปิดไฟล์ Excel 2007 / 2010 โดยตรงไม่ได้ เปิดแล้วเป็นหน้าขาว ต้องใช้ Open ถึงเปิดได้

กรณี เปิดไฟล์ Excel 2007 / 2010 โดยตรงไม่ได้ เปิดแล้วเป็นหน้าขาว ต้องใช้ Open ถึงเปิดได้ บางคนอาจแก้ โดยการเข้าไป ติ๊กเอาค่านึง ใน Excel Option ตามตัวอย่างในเน็ตออกแล้วหายก็โชดดีไปครับ แต่ของผมลองแล้วไม่หายค้นหาข้อมูลฝรั่งทำไว้พบว่าทำแบบนี้แล้วหาย มาดูวิธีการกันครับ

1. กดปุ่ม Windows+R (เผื่อมีคนไม่เข้าใจ หมายถึงกดปุ่ม รูป Windows ที่คีย์บอร์ดค้างไว้แล้วกดตัว R)

2. พิมพ์ Excel.exe /regserver ลงในช่องเสร็จแล้วกดปุ่ม OK

3. หลังจากขั้นตอนที่ 2. ถ้ามี Error หรืออะไรขึ้นมาก็ตอบ OK หรือ Yes ไปก่อน ผมจำหน้าจอไม่ได้ 55

4. พอโปรแกรม Excel เปิดมาเป็นหน้าขาวปกติแล้วก็ปิด Excel ไป แล้วลองเปิดไฟล์ Excel นั้นๆ อีกที

ถ้ายังเปิดไม่ได้ให้ ทำขั้นตอน 1-3 ใหม่ แล้วให้ลองเปลี่ยนไปเปิดไฟล์ Excel  อื่นๆ ดูก่อน ไฟล์ที่คิดว่าเคยเปิดได้อยู่แล้วก่อนหน้านี้ เพราะบางทีไฟล์ Excel ที่คุณพยายามเปิดอยู่ อาจจะติดไวรัสอะไรเข้าไปหรือไฟล์เสียหายแล้วทำให้ Excel ทำงานผิดปกตินั่นเองครับ

โชคดี

วันพุธที่ 14 พฤศจิกายน พ.ศ. 2561

Outlook 2007 / 2010 เปิดไฟล์แนบไม่ได้ Error : right-click the folder you want to create the file in, and then click Properties on the shortcut menu to check your permissions for the folder

Outlook 2007 / 2010 เปิดไฟล์แนบไม่ได้

Error : right-click the folder you want to create the file in, and then click Properties on the shortcut menu to check your permissions for the folder

ให้ลองสร้าง Folder มา Folder นึง ชื่อ C:\TMP ก็ได้

เข้า Registry
ไปที่ Key

Outlook 2007
HKEY_CURRENT_USER\Software\Microsoft\Office\12\Outlook\Security\

Outlook 2010
HKEY_CURRENT_USER\Software\Microsoft\Office\14.0\Outlook\Security\

ดับเบิ๊ลคลิ๊กที่ OutlookSecureTempFolder.
ที่ช่อง Value Data ให้แก้เป็น  C:\TMP\  เเล้วกด OK
ออกจากหน้า Registry Editor

Kill Explorer Process แล้ว Run Explorer อีกครั้ง
หรือ
Restart เครื่อง computer ก็ได้แล้วแต่ถนัด

ลองเปิดไฟล์ที่มีปัญหาดูอีกครั้ง
โชคดี ครับ

วันศุกร์ที่ 26 ตุลาคม พ.ศ. 2561

แก้ IP Gateway DNS ( Ubuntu )

แก้ IP Gateway DNS ( Ubuntu )
นานๆ ใช้ที ก็เลยลืม Note เอาไว้ก่อน

nano /etc/hostname

Check IP Address
ifconfig -a

Edit Interface
nano /etc/network/interfaces

Edit DNS
nano /etc/resolv.conf

Restart Interface
/etc/init.d/networking restart

จบข่าว...

วันเสาร์ที่ 20 ตุลาคม พ.ศ. 2561

Arduino Happy Birthday Song

//Sound frequency note By Yoshioka

float G_LL = 783.991;
float A_L = 880;
float B_L = 987.767;
float C_L = 1046.50;
float D_L = 1174.66;
float E_L = 1318.51;
float F_L = 1396.91;
float G_L = 1567.98;
float A_M = 1760.00;
float B_M = 1975.53;
float C_M = 2093.00;
float D_M = 2349.32;
float E_M = 2637.02;
float F_M = 2793.83;
float G_M = 3135.96;
float A_H = 3520.00;
float B_H = 3951.07;

void happybirthdaysong()
{
  tone(speakerPin, G_LL, 200);
  delay(200);
  tone(speakerPin, G_LL, 200);
  delay(200);
  tone(speakerPin, A_L, 400);
  delay(400);
  tone(speakerPin, G_LL, 400);
  delay(400);
  tone(speakerPin, C_L, 400);
  delay(400);
  tone(speakerPin, B_L, 800);
  delay(1000); 

  tone(speakerPin, G_LL, 200);
  delay(200);
  tone(speakerPin, G_LL, 200);
  delay(200);
  tone(speakerPin, A_L, 400);
  delay(400);
  tone(speakerPin, G_LL, 400);
  delay(400);
  tone(speakerPin, D_L, 400);
  delay(400);
  tone(speakerPin, C_L, 800);
  delay(1000); 

  tone(speakerPin, G_LL, 200);
  delay(200);
  tone(speakerPin, G_LL, 200);
  delay(200);
  tone(speakerPin, G_L, 400);
  delay(400);
  tone(speakerPin, E_L, 400);
  delay(400);
  tone(speakerPin, C_L, 400);
  delay(400);
  tone(speakerPin, B_L, 400);
  delay(400);
  tone(speakerPin, A_L, 800);
  delay(1000);

  tone(speakerPin, F_L, 200);
  delay(200);   
  tone(speakerPin, F_L, 200);
  delay(200);     
  tone(speakerPin, E_L, 400);
  delay(400);     
  tone(speakerPin, C_L, 400);
  delay(400);       
  tone(speakerPin, D_L, 600);
  delay(400);       
  tone(speakerPin, C_L, 900);
  delay(1000);         
  }

Arduino Days of Week

void daysofweek()
{
int d    = 6;         //Day     1-31
int m    = 9;       //Month   1-12
int y    = 1982;     //Year    1982

int weekdays  = (d += m < 3 ? y-- : y - 2, 23*m/9 + d + 4 + y/4- y/100 + y/400)%7;
Serial.println(weekdays);
}

วันจันทร์ที่ 1 ตุลาคม พ.ศ. 2561

ฮอตสปอต iPhone ไม่ได้

ปัญหาการปล่อยฮอตสปอตของ iPhone จริงๆ แล้วหลายๆ คนคิดว่ามันเป็นเรื่องง่ายๆ บางครั้งเปิดแชร์ไปยังไงก็ได้ แต่บางทีก็แชร์ยากมากๆ ต้องปิดเปิดฮอตสปอตบ่อยๆ ต้องมีการเสียบสายให้แชร์ผ่าน USB ก่อนถึงจะมองเห็นวายฟายฮอตสปอตที่แชร์ อะไรแบบนั้น ซึ่งทำให้หลายคนสงสัยว่าทำไม iPhone จึงแชร์ยากเย็นจัง จริงๆ มีเทคนิคง่ายๆ ที่เรามองข้ามไปผมสรุปไว้ดังนี้

หลายๆ ครั้งที่มีคนถามผมเลยคิดว่าเผื่อจะมีใครติดปัญหาแล้ว Search มาเจอวิธีของผมบ้างอาจจะช่วยท่านได้

1. ตั้งชื่อเครื่อง iPhone ให้แตกต่างจากคนอื่นๆ เขา เช่น iCAT, iDOG, iBIRD, iSAAD เอาว่าที่ไม่ใช่ชื่อตั้งต้นที่เขาตั้งมาให้ก็แล้วกันนะครับ จะได้ไม่ไปเชื่อมเครื่องคนอื่นเขาทำให้สับสนเฉยๆ

2. อันนี้สำคัญ ***ตั้งรหัสผ่านที่ต้องประกอบไปด้วย ตัวอักษรใหญ่ 2 ตัว เล็ก 2 ตัว และก็ตัวเลข รวมกันแล้วให้ครบ 8  ตัว อย่างน้อย หรืออาจจะมีอัขระพิเศษเข้าไปด้วยก็ได้ครับ เช่น HHH$hhh44 หรือ hhh#HHH44 เป็นต้น ทำไมต้องตั้งแบบนี้หรอครับ ผมลองดูแล้ว ถ้าตั้งแบบนี้ จะเห็น ฮอตสปอตของ iPhone เร็วและได้ตลอด แต่ถ้าเปลี่ยนเป็นแบบง่ายๆ เช่น 12345678 แบบนี้ เปิดแล้วไม่ค่อยจะ Search เจอครับ อาจจะเป็นไปได้ว่าเค้าบังคับให้ตั้งรหัสให้คาดเดายากขึ้นถึงจะยอมให้ปล่อย ฮอตสปอตครับ

3. ให้เปิดหน้าแชร์ ฮอตสปอตไว้จนกว่าเครื่องที่เราแชร์จะเชื่อมกับเราได้สำเร็จ

เพียงเท่านี้ผมว่าน่าจะหมดปัญญาที่เป็นข้อสงสัยกับใครหลายคนว่าทำไมแชร์เน็ต iPhone ยากไปได้นะครับ

แก้ Active Desktop Recovery

เข้าไปแก้ Value ในไฟล์ DeskHtmlVersion  ให้กลายเป็น 0 ไม่ให้แสดงหน้าต่าง Active Desktop Recovery เข้าไปที่  HKEY_CURRENT_USER/Software/Mi...