- html - 出于某种原因,IE8 对我的 Sass 文件中继承的 html5 CSS 不友好?
- JMeter 在响应断言中使用 span 标签的问题
- html - 在 :hover and :active? 上具有不同效果的 CSS 动画
- html - 相对于居中的 html 内容固定的 CSS 重复背景?
面对 pysnmp 代理返回值的奇怪问题。
PYSNMP 代理接收字符串格式为 "0a0a0a0a0a0a0a0a0a"
.
在 MIB 中,OID 表示为 HEXA STRING。
当尝试使用 rfc1902.OctetString(hexValue=str_temp)
返回字符串时,输出为空,因为六值(0a0a0a)
被解码为新行 (\n)
人物。
SNMPv2-SMI::example.154.12.1.0 = STRING: "
"
str="0a0a0a0a0a0a0a0a"
After Return using rfc1902.OctetString(str) or rfc1902.OctetString(hexaValue=str)
SNMPv2-SMI::example.154.12.1.0 = Hex-STRING: 0A 0A 0A 0A 0A 0A 0A 0A
最佳答案
for oid, val in varBinds:
print(oid.prettyPrint(),' = ',val.prettyPrint())
关于python - PYSNMP 代理在解码 Hexa 值后返回换行符作为输出,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/62082050/
我有一个名为 const char receiptLogo[] = {0x01,0x80,0x00,0xB4}; 当我试图获取值时 Rprintf("%x\r\n",receiptLogo[3]);
面对 pysnmp 代理返回值的奇怪问题。 PYSNMP 代理接收字符串格式为 "0a0a0a0a0a0a0a0a0a" . 在 MIB 中,OID 表示为 HEXA STRING。 当尝试使用 rf
我正在尝试将颜色值更改为颜色hexa代码。所以,我的代码是这样的: color = Integer.toHexString(colorpick.getValue().hashCode()).subst
为什么三个运算符 #include using namespace std; int main() { operator<<(cout, "Hello").operator<<('w').ope
我正在学习理解线程转储,并且创建了一个示例应用程序来模拟死锁条件。 以下是完整代码: Thread1.java package com.example.threads.deadlock; public
我已经使用 Flask 在本地服务器中创建了一个 Restfull API。 我在六边形的编码/解码方面遇到了一些麻烦。 我创建了一个函数来调试我的问题: class test_encoding(Re
我正在使用 Java 8 和 I18N。根据我的理解,.properties 文件(以及后续的 I18N 代码)假定文件采用“ISO-8859-1”文件格式。因此,我遇到了无法以该文件格式表示的字符的
正在将 MongoDB 迁移到 postgres。 感谢 postgres JSON ,这使得将嵌套文档作为 JSON 移动变得容易。但问题始于迁移“ID”字段。 Mongo 生成一个大的十六进制数
我需要在 RS232 端口(串行)上使用指纹进行对话。我有一个非常有用的 python 代码: import serial import time ser = serial.Serial('/dev/
我想使用 HEXA 包发送 MIDI 音符。 G2、D♯3、D3 快速使用 coreMIDI 最佳答案 请参阅下面的 Midi 数据包以获取上述注意事项。 G2 var packet1:MID
我正在研究 iOS MDM。在注册期间,我获得了 deviceToken、PushMagic 和 unlockToken。计划使用javapns .它期望 64 十六进制值。 这是我原来的设备 tok
我是一名优秀的程序员,十分优秀!