Browse Source

test.py

master
Robin Thoni 9 years ago
parent
commit
3940b97dcd
1 changed files with 11 additions and 0 deletions
  1. 11
    0
      test.py

+ 11
- 0
test.py View File

1
+#! /usr/bin/env python
2
+
3
+import dhcp_client
4
+
5
+dh = dhcp_client.DhcpClient()
6
+offer = dh.get_offer('00:15:00:ba:60:da', 'eth0')
7
+#offer = dh.get_offer('08:00:27:45:60:dc', 'wlan0')
8
+if offer == None:
9
+    print("Timeout")
10
+else:
11
+    print(offer.str())

Loading…
Cancel
Save